<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateCaseCasesTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('case_cases', function (Blueprint $table) {
            $table->increments('id');
            $table->string('title')->default('')->comment('案件标题');
            $table->integer('case_batch_id')->comment('所属委托');
            $table->integer('admin_user_id')->nullable()->comment('负责律师');
            $table->integer('trial_num')->default('1')->comment('审判次');
            $table->integer('trial_step')->default('1')->comment('审判阶段');
            $table->json('fields')->nullable()->comment('自定义字段');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('case_cases');
    }
}
